package main

import (
	"fmt"
	_ "gin-AssetManagement/inits"
	_ "gin-AssetManagement/inits/mysqlinit"
	_ "gin-AssetManagement/inits/redisinit"
	"gin-AssetManagement/routes"
	"github.com/spf13/viper"
)

func main() {
	port := fmt.Sprintf("%v", viper.Get("server.port"))
	r := routes.GinRoute()
	err := r.Run(":" + port) // 监听并在 0.0.0.0:8081 上启动服务
	if err != nil {
		panic(err)
	}
}
